
import React, { useState } from 'react';
import { Row, Col, Card, Switch, Statistic, Tooltip, Space, Tabs } from 'antd'
import { history, connect } from 'umi';
import { ExclamationCircleOutlined, } from '@ant-design/icons'
import RewardTemplate from './components/basicReward'
import ExtraRewards from './components/extraRewards'
const Customer = (props) => {
    const { } = props
    const [activeTabKey, setActiveTabKey] = useState('basicReward');
    const tabList = [
        {
            label: `基础奖励配置`,
            key: 'basicReward',
            children: <RewardTemplate rewardType={'normal'}></RewardTemplate>,

        },
        {
            label: `额外任务奖励`,
            key: 'extraRewards',
            children: <ExtraRewards rewardType={'additional'} ></ExtraRewards>
        },
    ];

    const onTabChange = (key) => {
        setActiveTabKey(key);
    };
    return <Card style={{
        width: '100%',
        minHeight: 900
    }}>
        <Tabs
            destroyInactiveTabPane={true}
            onChange={onTabChange}
            activeKey={activeTabKey}
            items={tabList}
            type="card"
        >
        </Tabs>

    </Card>


}

export default connect(({ loading }) => ({

    loading: loading.models.institution,
}))(Customer);
